<template>
	<uv-popup safeAreaInsetBottom ref="popup" mode="bottom" round="12" @maskClick="maskClick">
		  <!-- 1. 一键授权登录 accountLogin -->
		<accountLogin v-if="authType == 'accountLogin'" />
		<!-- #ifdef H5 -->
		<uv-tabbar></uv-tabbar>
		<!-- #endif -->
	</uv-popup>
</template>

<script setup>
	import sheep from "@/sheep"
	import accountLogin from "./components/account-login.vue"
	const popup = ref()
	const modalStore = sheep.$store('modal');
	import { closeAuthModal } from '@/sheep/hooks/useModal';
	// 授权弹窗类型
	const authType = computed(() => modalStore.auth);
	watch(authType,(value) => {
		if(!!value) popup.value.open()
		else popup.value.close()
	})
	function maskClick(){
		closeAuthModal()
	}
</script>

<style>

</style>